<script language="javascript">
    $(document).ready(function() {
        $("#admin li").removeClass("content_2_z2"); //去掉所有SPAN的样式
        var f='{$left}';
        if((f=='admin_ffgl')||(f=='admin_dygl')||(f=='admin_dyfl')||(f=='admin_m1905')){
            $("#testli").addClass("content_2_z2");
            document.getElementById("test").style.display="block";
            $("#{$left}").addClass("content_2_z3");
        }else if((f=='admin_hinfo')||(f=='admin_hotelName')||(f=='admin_hotelGroup')||(f=='admin_hotelArea')||(f=='admin_hotelUser')||(f=='admin_hinfoAll')){
            $("#hotelli").addClass("content_2_z2");
            document.getElementById("hotel").style.display="block";
            $("#{$left}").addClass("content_2_z3");
        }else if((f=='admin_kftj')||(f=='admin_countcheckin')||(f=='admin_totalcount')||(f=='admin_group')||(f=='admin_area')||(f=='admin_mViewStats')||(f=='admin_targetStatistics')||(f=='admin_process')){
            $("#checkinli").addClass("content_2_z2");
            document.getElementById("checkin").style.display="block";
            $("#{$left}").addClass("content_2_z3");
        }else if((f=='admin_singlepay')||(f=='admin_allpay')||(f=='admin_allname')){
            $("#priceli").addClass("content_2_z2");
            document.getElementById("price").style.display="block";
            $("#{$left}").addClass("content_2_z3");
        }else if((f=='admin_operationData')||(f=='admin_operationNotice')||(f=='email_list')||(f=='admin_operationDefault')){
        	$("#operationsli").addClass("content_2_z2");
            document.getElementById("operations").style.display="block";
            $("#{$left}").addClass("content_2_z3");
        }else if((f=='admin_wxpsPacks')||(f=='admin_wxpsSends')||(f=='admin_wxpsStats')){
            $("#wxpsli").addClass("content_2_z2");
            document.getElementById("wxpsli").style.display="block";
            $("#{$left}").addClass("content_2_z3");
            $("#wxps").show();
        }else{
            $("#{$left}").addClass("content_2_z2");
        }
//	$("#{$left}").addClass("content_2_z2");
        $("#head li a").removeClass("headBlue"); //去掉所有SPAN的样式
        $("#head_1 a").addClass("headBlue");

    });

    function test(){
        $("#admin li").removeClass("content_2_z2"); //去掉所有SPAN的样式
        $("#testli").addClass("content_2_z2");
        var divD = document.getElementById("test");
        if(divD.style.display=="none")
        {
            //  $("#test").show(400);
            divD.style.display = "block";
        }
        else
        {
            //   $("#test").hide(400);
            divD.style.display = "none";
        }
    }
    function do_hotel(){
        $("#admin li").removeClass("content_2_z2"); //去掉所有SPAN的样式
        $("#hotelli").addClass("content_2_z2");
        var divD = document.getElementById("hotel");
        if(divD.style.display=="none")
        {
            //  $("#test").show(400);
            divD.style.display = "block";
        }
        else
        {
            //   $("#test").hide(400);
            divD.style.display = "none";
        }
    }
    function setCss(flag){
        $("#admin li").removeClass("content_2_z2"); //去掉所有SPAN的样式
        $("#"+flag+"li").addClass("content_2_z2");
        var divD = document.getElementById(flag);
        if(divD.style.display=="none")
        {
            //  $("#test").show(400);
            divD.style.display = "block";
        }
        else
        {
            //   $("#test").hide(400);
            divD.style.display = "none";
        }
    }
</script>
<style type="text/css">
    .arrow{
        position: absolute; background: url(__PUBLIC__/images/jt2.png) no-repeat 0 0;margin-left: 30px;margin-top: 15px;
        width: 21px; height: 15px;
    }
</style>
<div class="content_2_z left" id='admin'>
    <ul >
        <li class="content_2_z1">系统管理模块</li>
        <?php



        if(strstr($admin_permission,"manage_hinfo,")||strstr($admin_permission,"manage_hinfoAll,")||strstr($admin_permission,"manage_hotelName,")||strstr($admin_permission,"manage_hotelGroup,")||strstr($admin_permission,"manage_hotelArea,")||strstr($admin_permission,"manage_hotelUser,")){
   ?>
        <li id="hotelli"><a href="#" onclick="do_hotel()"><img src="__PUBLIC__/images/jt.png">酒店管理<span class="arrow"></span> </a>

            <ul id="hotel" style="margin-left: 20px;display: none;">
                <?php

                if(strstr($admin_permission,"manage_hinfo,")){
            ?>
                <li id='admin_hinfo'><a href="__APP__/admin/hinfo"><img src="__PUBLIC__/images/jt.png">酒店状态</a></li>
                <li id='admin_hinfoAll'><a href="__APP__/admin/hinfoAll"><img src="__PUBLIC__/images/jt.png">酒店分布</a></li>
                <?php
               }
                if(strstr($admin_permission,"manage_hotelName,")){
            ?>
                <li id='admin_hotelName'><a href="__APP__/admin/hotelName"><img src="__PUBLIC__/images/jt.png" />酒店信息</a></li>
                <?php
    	         }
    	          if(strstr($admin_permission,"manage_hotelGroup,")){
            ?>
                <li id='admin_hotelGroup'><a href="__APP__/admin/hotelGroup"><img src="__PUBLIC__/images/jt.png" />酒店分类</a></li>
                <?php
    	         }
    	          if(strstr($admin_permission,"manage_hotelArea,")){
            ?>
                <!--<li id='admin_hotelArea'><a href="__APP__/admin/hotelArea"><img src="__PUBLIC__/images/jt.png" />区域管理</a></li>-->
                <?php
    	         }
    	          if(strstr($admin_permission,"manage_hotelUser,")){
            ?>
                <li id='admin_hotelUser'><a href="__APP__/admin/hotelUser"><img src="__PUBLIC__/images/jt.png" />特殊用户管理</a></li>
                <?php
    	         }
            ?>
            </ul>
			</li>
            <?php
    	}

   	 	   if(strstr($admin_permission,"manage_ffgl,")||strstr($admin_permission,"manage_dygl,")||strstr($admin_permission,"manage_dyfl,")||strstr($admin_permission,"manage_m1905,")){
    ?>
        <li id="testli"><a href="#" onclick="test()"><img src="__PUBLIC__/images/jt.png">影院管理<span class="arrow"></span> </a>
            <ul id="test" style="margin-left: 20px;display: none;">
                <?php

   	 	   if(strstr($admin_permission,"manage_ffgl,")){
    ?>
                <li id='admin_ffgl'><a href="__APP__/admin/ffgl" ><img src="__PUBLIC__/images/jt.png">分发管理</a></li>
                <?php
   	}
    	   if(strstr($admin_permission,"manage_dygl,")){
    ?>
                <li id='admin_dygl' ><a href="__APP__/admin/dygl"  ><img src="__PUBLIC__/images/jt.png">电影管理</a></li>
                <?php
   	}
    	   if(strstr($admin_permission,"manage_dyfl,")){
    ?>
                <li id='admin_dyfl' ><a href="__APP__/admin/dyfl"  ><img src="__PUBLIC__/images/jt.png">影库管理</a></li>
                <?php
    	}
    	if(strstr($admin_permission,"manage_m1905,")){
    ?>
                <!--<li id='admin_m1905' ><a href="__APP__/admin/m1905"  ><img src="__PUBLIC__/images/jt.png">1905分发管理</a></li>-->
                <?php
    	}
    ?>
            </ul>
            </li>
            <?php
    	}
    	 	   if(strstr($admin_permission,"manage_singlepay,")||strstr($admin_permission,"manage_allpay,")||strstr($admin_permission,"manage_allpayName,")){
    ?>
        <li id="priceli"><a href="#" onclick="setCss('price')"><img src="__PUBLIC__/images/jt.png">价格管理<span class="arrow"></span> </a>
            <ul id="price" style="margin-left: 20px;display: none;">
                <?php

   	 	   if(strstr($admin_permission,"manage_singlepay,")){
    ?>
                <li id='admin_singlepay'><a href="__APP__/admin/singlepay" ><img src="__PUBLIC__/images/jt.png">单片管理</a></li>
                <?php
   	}
    	   if(strstr($admin_permission,"manage_allpay,")){
    ?>
                <li id='admin_allpay' ><a href="__APP__/admin/allpay"  ><img src="__PUBLIC__/images/jt.png">包片管理</a></li>
                <?php
   	}
           if(strstr($admin_permission,"manage_allname,")){
    ?>
                <li id='admin_allname'><a href="__APP__/admin/allpayName" ><img src="__PUBLIC__/images/jt.png">包名管理</a></li>
                <?php
   	}
    ?>
            </ul>
            </li>
            
             <?php
    	}
    	 	   if(strstr($admin_permission,"manage_operationData,")||strstr($admin_permission,"manage_operationNotice,")||strstr($admin_permission,"manage_emaillist,")||strstr($admin_permission,"manage_operationDefault,")){
    ?>
        <li id="operationsli"><a href="#" onclick="setCss('operations')"><img src="__PUBLIC__/images/jt.png">运维管理<span class="arrow"></span> </a>
            <ul id="operations" style="margin-left: 20px;display: none;">
                <?php

   	 	   if(strstr($admin_permission,"manage_operationData,")){
    ?>
                <li id='admin_operationData'><a href="__APP__/admin/operationData" ><img src="__PUBLIC__/images/jt.png">运维信息</a></li>
                <?php
   			}
			if(strstr($admin_permission,"manage_emaillist,")){
    		?>
	    	<li id='email_list'><a href="__APP__/admin/emailManage" ><img src="__PUBLIC__/images/jt.png">邮件设置</a></li>
	           <?php
	   		}
		if(strstr($admin_permission,"manage_operationNotice,")){
    	?>
	        <li id='admin_operationNotice'><a href="__APP__/admin/operationNotice" ><img src="__PUBLIC__/images/jt.png">报警设置</a></li>
	           <?php
		}
 		 if(strstr($admin_permission,"manage_operationDefault,")){
    ?>
                <li id='admin_operationDefault'><a href="__APP__/admin/operationDefault" ><img src="__PUBLIC__/images/jt.png">设置默认</a></li>
                <?php
   		}
    	?>
            </ul>
            </li>
            <?php
    	}
    		if(strstr($admin_permission,"manage_index,")){

     ?>
        <li class="content_2_z2" id='admin_index'><a href="__APP__/admin/admin_index"><img src="__PUBLIC__/images/jt.png">账单管理</a></li>
        <?php
    	}
    	  	   if(strstr($admin_permission,"manage_sjtj,")){
    ?>
        <!--<li id='admin_sjtj'><a href="__APP__/admin/sjtj"><img src="__PUBLIC__/images/jt.png">数据统计</a></li>-->

        <?php
   	}
       if(strstr($admin_permission,"manage_countcheckin,")||strstr($admin_permission,"manage_subsouGroup,")||strstr($admin_permission,"manage_subsouArea,")||strstr($admin_permission,"manage_mViewStats,")||strstr($admin_permission,"manage_targetStatistics,")){
   ?>
        <li id="checkinli"><a href="#" onclick="setCss('checkin')"><img src="__PUBLIC__/images/jt.png">数据统计<span class="arrow"></span> </a>
            <ul id="checkin" style="margin-left: 20px;display: none;">
                <li id='admin_totalcount'><a href="__APP__/admin/totalcount"><img src="__PUBLIC__/images/jt.png">总体数据</a></li>
                <?php
                if(strstr($admin_permission,"manage_countcheckin,")){
            ?>
                <li id='admin_countcheckin'><a href="__APP__/admin/countcheckin"><img src="__PUBLIC__/images/jt.png">入住统计</a></li>
                <?php
               }
                if(strstr($admin_permission,"manage_mViewStats,")){
    ?>
                <li id='admin_mViewStats'><a href="__APP__/admin/mViewStats"><img src="__PUBLIC__/images/jt.png">行为统计</a></li>
                <?php
    	}
    	 if(strstr($admin_permission,"manage_targetStatistics,")){
    ?>
                <li id='admin_targetStatistics'><a href="__APP__/admin/targetStatistics"><img src="__PUBLIC__/images/jt.png">目标统计</a></li>
                <li id='admin_process'><a href="__APP__/admin/process"><img src="__PUBLIC__/images/jt.png">业务流程</a></li>
                <?php
    	}
                if(strstr($admin_permission,"manage_subsouGroup,")){
            ?>
                <!--<li id='admin_group'><a href="__APP__/admin/subsouGroup"><img src="__PUBLIC__/images/jt.png">集团统计</a></li>-->
                <?php
               }
                if(strstr($admin_permission,"manage_subsouArea,")){
            ?>
                <!--<li id='admin_area'><a href="__APP__/admin/subsouArea"><img src="__PUBLIC__/images/jt.png">区域统计</a></li>-->
                <?php
    	         }
            ?>
            </ul>
            </li>
            <?php
    	}
		if(strstr($admin_permission,"manage_wxpsPacks,")||strstr($admin_permission,"manage_wxpsSends,")||strstr($admin_permission,"manage_wxpsStats,")){
    ?>
        <li id="wxpsli"><a href="#" onclick="setCss('wxps');"><img src="__PUBLIC__/images/jt.png">剧透社<span class="arrow"></span></a>
            <ul id="wxps" style="margin-left: 20px;display: none;">
                <?php

   	 	   if(strstr($admin_permission,"manage_wxpsPacks,")){
    	?>
	                <li id='admin_wxpsPacks'><a href="__APP__/admin/wxpsPacks" ><img src="__PUBLIC__/images/jt.png">包管理</a></li>
	                <?php
	   	}
    	   if(strstr($admin_permission,"manage_wxpsSends,")){
    	?>
	                <li id='admin_wxpsSends' ><a href="__APP__/admin/wxpsSends"  ><img src="__PUBLIC__/images/jt.png">分发管理</a></li>
	                <?php
	   	}
    	   if(strstr($admin_permission,"manage_wxpsStats,")){
    	?>
	                <li id='admin_wxpsStats' ><a href="__APP__/admin/wxpsStats"  ><img src="__PUBLIC__/images/jt.png">信息统计</a></li>
	                <?php
	    	}
    	?>
	            </ul>
	            <?php
	    	}
   		 ?>
        </li>
        <!--<li id='admin_ccgl' ><a href="__APP__/admin/ccgl"  ><img src="__PUBLIC__/images/jt.png">存储管理</a></li>-->

    </ul>

</div>
